import Vue from 'vue'
import Vuex from 'vuex'
import axios from 'axios'
Vue.use(Vuex)
export default new Vuex.Store({
  state: {
      data:[]
  },
  mutations: {
      getdata(state,res){
        state.data = res.data.data
      }
  },
  actions: {
    getdata(context){
      axios.post('apis/pc_bookinfo').then(res=>{
        
        context.commit('getdata',res)
      })
    }
 
  },
  modules: {
  }
})
